﻿#pragma execution_character_set("utf-8")
#include <QCoreApplication>
#include "Person.h"
#include "Finery.h"
#include <QDebug>

int main(int argc, char *argv[])
{
    QCoreApplication a(argc, argv);

    Person* xc = new Person("小菜");
    qDebug() << "\n第一种装扮：";
    TShirts* dtx = new TShirts();
    BigTrouser* kk = new BigTrouser();
    Sneakers*  pqx = new Sneakers();
    pqx->Decorate(xc);
    kk->Decorate(pqx);
    dtx->Decorate(kk);
    dtx->Show();

    qDebug() << "\n第二种装扮：";
    LeatherShoes* px = new LeatherShoes();
    Tie* ld = new Tie();
    Suit* xz = new Suit();
    px->Decorate(xc);
    ld->Decorate(px);
    xz->Decorate(ld);
    xz->Show();

    delete dtx;
    delete kk;
    delete pqx;
    delete xz;
    delete ld;
    delete px;
    delete xc;

    return a.exec();
}
